/* 
 * File:   lattice.hpp
 * Author: mikdebian
 *
 * Created on July 10, 2013, 3:30 AM
 */

#ifndef LATTICE_HPP
#define	LATTICE_HPP

/**
 * Maximal number of atoms in a modeling cell
 */
#define MAX_NUMBER_OF_CELL_ATOMS 256

/**
 * Maximal number of atoms in the lattice
 */
#define MAX_NUMBER_OF_ATOMS 1024

/**
 * Maximal number of neighbor atoms
 */
#define MAX_NEIGHBORS 128 

/**
 * Internal atom
 */
#define LATTICE_INTERNAL_ATOM 1 

struct Lattice {
    /**
     * Atom chemical types
     */
    int mTypes[MAX_NUMBER_OF_ATOMS];
    
    /**
     * Atom attributes
     */
    unsigned int mAttributes[MAX_NUMBER_OF_ATOMS];
    
    /**
     * The the "fraction" of the atom in a cell
     */
    double mFractions[MAX_NUMBER_OF_CELL_ATOMS];
    
    /**
     * Atom coordinates
     */
    double mCoor[MAX_NUMBER_OF_ATOMS][3];
    
    /**
     * Neighbors (the first number in the row is the number of neighbors)
     */
    int mNei[MAX_NUMBER_OF_CELL_ATOMS][MAX_NEIGHBORS];    
    
    /**
     * Number of cell atom
     */
    int mNCell;
    
    /**
     * Total number of atoms
     */
    int mNA;
    
    /**
     * Lattice constant
     */
    double mLC;
};

#endif	/* LATTICE_HPP */

